package com.hoshiicloud.market.entity.market;

import java.io.Serializable;

import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.TableField;

import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import java.time.LocalDateTime;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;

import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 系统优惠券
 * </p>
 *
 * @author campchen
 * @since 2019-05-14
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("coupons")
public class Coupons implements Serializable {

    private static final long serialVersionUID = 1L;

    private Long id;

    /**
    * 租户ID
    */
    @TableField("conmpanyid")
    private Long conmpanyid;


    /**
    * 平台ID
    */
    @TableField("platformid")
    private Long platformid;


    /**
    * 店铺ID
    */
    @TableField("storeid")
    private Long storeid;


    /**
    * 优惠券编码
    */
    @TableField("coupon_no")
    private String couponNo;


    /**
    * 优惠券二维码内容
    */
    @TableField("coupon_qrcode")
    private String couponQrcode;


    /**
    * 优惠券名称
    */
    @TableField("coupon_name")
    private LocalDateTime couponName;


    /**
    * 是否现金券  1-现金券  2-折扣券
    */
    @TableField("credit")
    private Integer credit;


    /**
    * 面值
    */
    @TableField("amount")
    private BigDecimal amount;


    /**
    * 折扣率
    */
    @TableField("discount")
    private BigDecimal discount;


    /**
    * 生效日期
    */
    @TableField("from_date")
    private LocalDateTime fromDate;


    /**
    * 领券后N天失效
    */
    @TableField("got_dates")
    private Long gotDates;


    /**
    * 失效日期
    */
    @TableField("to_date")
    private LocalDateTime toDate;

    /**
     * 创建人
     */
    @TableField("createdby")
    private LocalDateTime createdby;

    /**
    * 建立时间
    */
    @TableField("createdtime")
    private LocalDateTime createdtime;


    /**
    * 修改人
    */
    @TableField("updatedby")
    private String updatedby;


    /**
    * 修改时间
    */
    @TableField("updatedtime")
    private LocalDateTime updatedtime;


    /**
    * 是否删除
    */
    @TableField("deleted")
    private Integer deleted;


    /**
    * 备注
    */
    @TableField("remark")
    private String remark;


    /**
    * 订单id
    */
    @TableField("orderid")
    private Long orderid;


    /**
    * 会员ID
    */
    @TableField("memberid")
    private Long memberid;



}
